/**
 * 
 */
package due.pc.pcshoot.entity;

import org.anddev.andengine.engine.Engine;
import org.anddev.andengine.opengl.texture.Texture;
import org.anddev.andengine.opengl.texture.TextureOptions;
import org.anddev.andengine.opengl.texture.region.TextureRegionFactory;
import org.anddev.andengine.opengl.texture.region.TiledTextureRegion;

import android.content.Context;

/**
 * @author manhhung.vu
 *
 */
public class Helicopter extends BaseEnemy 
{
	//===============================================================/
	//Constants
	//===============================================================/
	public static final int HELICOPTER_WIDTH = 64;
	public static final int HELICOPTER_HEIGHT = 64;
	
	public static final String HELICOPTER_IMAGEPATH = "gfx/helicopter_tiled.png";
	
	//===============================================================/
	//Fields
	//===============================================================/
	
	
	//===============================================================/
	//Constructors
	//===============================================================/
	/**
	 * @param pX
	 * @param pY
	 * @param pTileWidth
	 * @param pTileHeight
	 * @param pTiledTextureRegion
	 */
	private Helicopter(
			float pX, float pY, float pTileWidth, float pTileHeight,
			TiledTextureRegion pTiledTextureRegion) 
	{
		super(pX, pY, pTileWidth, pTileHeight, pTiledTextureRegion);
		// TODO Auto-generated constructor stub
	}

	//===============================================================/
	//Methods
	//===============================================================/
	
	
	
	//===============================================================/
	//Getters & Setters
	//===============================================================/
	
	
	//===============================================================/
	//Static Methods
	//===============================================================/
	public static Helicopter createHelicopter(float pX, float pY, Engine pEngine, Context pContext)
	{
		Texture helicopterTexture = new Texture(128, 128, TextureOptions.BILINEAR_PREMULTIPLYALPHA);
		TiledTextureRegion helicopterTextureRegion = TextureRegionFactory.createTiledFromAsset(
				helicopterTexture, pContext, HELICOPTER_IMAGEPATH, 0, 0, 2, 2);
		pEngine.getTextureManager().loadTexture(helicopterTexture);
		
		Helicopter helicopter = new Helicopter(pX, pY, HELICOPTER_WIDTH, HELICOPTER_HEIGHT, helicopterTextureRegion);
		
		return helicopter;
	}

}
